@(pictures: List[Picture], keyId: String, vCode: String)
<table id="pictures" class="table table-hover">
    <thead>
        <tr>
            <th>Id</th>
            <th>Name</th>
            <th>Description</th>
            <th>Image</th>
            <th>Action</th>
        </tr>
    </thead>
    <tbody>
        @for(picture <- pictures) {
            <tr data-id="@picture.getId()">
                <td>@picture.getId()</td>
                <td>@picture.getName()</td>
                <td>@picture.getDescription()</td>
                <td><a target="_blank" href="@picture.getUrl()"><img width="50" height="50" src="@picture.getUrl()" /></a></td>
                <td class="span6">
                    <button class="btn btn-primary edit-model" data-url="@routes.Pictures.uploadForm(picture.getId())">Edit</button>
                    @if(keyId != null && vCode != null){
                        <button class="btn btn-danger delete-model" data-url="/pictures/@picture.getId()?keyId=@keyId&vCode=@vCode">Delete</button>
                    }
                    <span class="error"></span>
                </td>
            </tr>
        }
    </tbody>
</table>